<include file="Public:pagerForm" />

<div class="pageHeader">
	<form rel="pagerForm" onsubmit="return navTabSearch(this);" action="__URL__" method="post">
	<div class="searchBar">
		<ul class="searchContent">
			<li>
				<label>商品id：</label>
				<input type="text" name="commodity_id" value="{$_REQUEST.commodity_id}"/>
			</li>
			<li>
				<label><input type="checkbox" name="is_cancle" value="1" <?php if($_REQUEST['is_cancle']==1) echo "checked"?>/>已废除</label>
			</li>
		</ul>
		<div class="subBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">查询</button></div></div></li>
			</ul>
		</div>
	</div>
	</form>
</div>

<div class="pageContent">
	<div class="panelBar">
		<ul class="toolBar">
			<li><a class="add" href="__URL__/add" target="dialog" mask="true" width="800" height="480"><span>新增</span></a></li>
			<li><a class="edit" href="__URL__/edit/commodity_id/{commodity_id}" target="dialog" width="800" height="480" mask="true" warn="请选择商品"><span>编辑</span></a></li>
			<li><a class="edit" href="__URL__/categoryEdit/commodity_id/{commodity_id}" target="dialog" width="800" height="480" mask="true" warn="请选择商品"><span>分类设置</span></a></li>
			<li class="line">line</li>
			<li><a class="edit" href="__URL__/onSale/commodity_id/{commodity_id}" target="ajaxTodo" warn="请选择商品"><span>上架</span></a></li>
			<li><a class="edit" href="__URL__/offSale/commodity_id/{commodity_id}" target="ajaxTodo" warn="请选择商品"><span>下架</span></a></li>
			<php>if($_SESSION['administrator']==true){</php>
				<li><a class="delete" href="__URL__/doCancle/commodity_id/{commodity_id}/navTabId/__MODULE__" target="ajaxTodo" title="你确定要删除吗？" warn="请选择商品"><span>废除</span></a></li>
			<php>}</php>
			<li class="line">line</li>
			<li><a class="icon" href="__URL__/picEdit/commodity_id/{commodity_id}/type/1" target="dialog" width="800" height="480" mask="true" warn="请选择商品"><span>封面图设置</span></a></li>
			<li><a class="icon" href="__URL__/picEdit/commodity_id/{commodity_id}/type/2" target="dialog" width="800" height="480" mask="true" warn="请选择商品"><span>附属图设置</span></a></li>
			<li><a class="icon" href="__URL__/picEdit/commodity_id/{commodity_id}/type/3" target="dialog" width="800" height="480" mask="true" warn="请选择商品"><span>详情图设置</span></a></li>
		</ul>
	</div>

	<table class="table" width="100%" layoutH="138">
		<thead>
		<tr>
			<th width="60">编号</th>
			<th width="100" >商品名</th>
			<th width="100" >规格</th>
			<th width="100" >单位</th>
			<th width="100" >销售周期</th>
			<th width="100" >产地</th>
			<th width="100" >市场价</th>
			<th width="100" >销售价</th>
			<th width="60" >排序</th>
			<th width="100" >供应开始</th>
			<th width="100" >供应结束</th>
			<th width="100" >上架状态</th>
		</tr>
		</thead>
		<tbody>
		<volist id="vo" name="list">
			<tr target="commodity_id" rel="{$vo['commodity_id']}">
				<td>{$vo['commodity_id']}</td>
				<td>{$vo['name']}</td>
				<td>{$vo['spec']}</td>
				<td><php>echo C('GOODS_UNIT_NAME.'.$vo['unit_id']);</php></td>
				<td>{$vo['sale_cycle']}</td>
				<td>{$vo['origin']}</td>
				<td>{$vo['market_price']}</td>
				<td>{$vo['sale_price']}</td>
				<td>{$vo['sort']}</td>
				<td>{$vo['supply_begin']}</td>
				<td>{$vo['supply_end']}</td>
				<td><php>echo C('SALE_STATUS_NAME.'.$vo['is_onsale']);</php>
				<!--<a href="__URL__/resume/id/{$vo['id']}/navTabId/__MODULE__" target="ajaxTodo" callback="">恢复</a>
				<a href="__URL__/forbid/id/{$vo['id']}/navTabId/__MODULE__" target="ajaxTodo" callback="">禁用</a>-->
				</td>
			</tr>
		</volist>
		</tbody>
	</table>

	<div class="panelBar">
		<div class="pages">
			<span>共{$totalCount}条</span>
		</div>
		<div class="pagination" targetType="navTab" totalCount="{$totalCount}" numPerPage="{$numPerPage}" pageNumShown="10" currentPage="{$currentPage}"></div>
	</div>

</div>


